home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
FM Towns: Free Software Collection 6
/
FM Towns Free Software Collection 6.iso
/
t_os
/
vdtwn
/
tvf
/
asmhd6
/
tw1hd6
/
start1_n.hd6
< prev
next >
Wrap
Text File
|
1993-07-08
|
6KB
|
405 lines
ds_name db '\KOMEI\実物\TVF_PRG\START',0
paint_wd:
SET_P dt1
SET_P dt2
SET_P dt3
SET_P dt4
SET_P dt5
SET_P dt6
SET_P dt7
SET_P dt8
SET_P dt9
SET_P dt10
WD_LEFT
re_paint:
mouse_in:
ret
be_called:
push 0110h
pop fs
xor ah,ah ; EGB初期化
; lea edi,EGB_WORK
; mov ecx,1536
; call pword ptr fs:[EGB]
mov ax,0100h; 仮想画面の設定
mov dx,9
call zzz ;pword ptr fs:[EG]
mov ax,0101h
mov dx,9
call zzz ;pword ptr fs:[EG]
mov ax,0500h; 書き込みページの設定(ページ0)
call zzz ;pword ptr fs:[EG]
mov ax,0601h; 表次頁の設定(ページ1優先)
mov edx,11b
call zzz ;pword ptr fs:[EG]
mov ax,1B01h; ディジタイズ指定
call zzz ;pword ptr fs:[EG]
; xor ah,ah ; MouseBios初期化
; lea edi,MOUSE_WORK
; mov ecx,4096
; call pword ptr fs:[MB]
mov ah,7 ;水平移動範囲指定
mov dx,0
mov bx,180
call MOUSE ;pword ptr fs:[MB]
mov ah,8 ;垂直移動範囲指定
mov dx,0
mov bx,120
call MOUSE ;pword ptr fs:[MB]
init_1:
push ebp
push ds
push es
mov ax,1Ch ; 画面クリア
mov ds,ax
mov es,ax
mov eax,10000000000000001000000000000000b
mov edi,40000h
mov ebx,360*2/4
mov edx,400h-(360*2)
mov ebp,240
; align 4
rep_: mov ecx,ebx
rep stosd
add edi,edx
dec ebp
jne rep_
mov ax,0101h; キ-ボ-ド関係設定
int 90h
pop es
pop ds
pop ebp
key_check: mov ax,0901h
int 90h
xor dh,0FFh
je key_check
key: cmp dl,'0' ; キ-入力判定
je color_0
cmp dl,31h
je color_8
cmp dl,32h
je color_64
cmp dl,33h
je color_512
cmp dl,34h
je color_4096
; cmp dl,"5"
; je color_32768
cmp dl,"6"
je color_green
cmp dl,"7"
je color_red
cmp dl,"8"
je color_blue
cmp dl,"9"
je color_nega
cmp dl,"*"
je color_yellow
cmp dl,"Y"
je color_yellow
cmp dl,"y"
je color_yellow
cmp dl,"/"
je color_violet
cmp dl,"V"
je color_violet
cmp dl,"v"
je color_violet
cmp dl,"+"
je color_skyblue
cmp dl,"S"
je color_skyblue
cmp dl,"s"
je color_skyblue
cmp dl,"-"
je jmp_mosaic1
cmp dl,"Z"
je jmp_mosaic1
cmp dl,"z"
je jmp_mosaic1
cmp dl,"="
je jmp_mosaic2
cmp dl,"X"
je jmp_mosaic2
cmp dl,"x"
je jmp_mosaic2
cmp dl,"."
je jmp_mosaic3
cmp dl,"C"
je jmp_mosaic3
cmp dl,"c"
je jmp_mosaic3
cmp dl,"K"
je jt_koma1
cmp dl,"k"
je jt_koma1
cmp dl,"L"
je jt_koma2
cmp dl,"l"
je jt_koma2
cmp dl,"D"
je jt_koma4
cmp dl,"d"
je jt_koma4
cmp dl,";"
je jt_koma3
cmp dl,"R"
je rever
cmp dl,"r"
je rever
cmp dl,"M"
je monotone
cmp dl,"m"
je monotone
cmp dl,""
je zoom_up
cmp dl,""
je zoom_up2
cmp dl,""
je zoom_up3
cmp dl,13 ;return_key
je quit
cmp dl,20h
je key_check
jmp init_1
;===== Table for jump =====
color_0: mov eax,10000000000000000000000000000000b ;論理演算用
jmp key1
color_8:
mov eax,11000010000100001100001000010000b ;論理演算用
jmp key1
color_64: mov eax,11100011000110001110001100011000b ;論理演算用
jmp key1
color_512: mov eax,11110011100111001111001110011100b ;論理演算用
jmp key1
color_4096: mov eax,11111011110111101111101111011110b ;論理演算用
jmp key1
;#color_32768: mov ebp,11111111111111111111111111111111b ;論理演算用
; jmp draw_main1
color_green: mov eax,11111100000000001111110000000000b ;論理演算用
jmp key1
color_red: mov eax,10000011111000001000001111100000b ;論理演算用
jmp key1
color_blue: mov eax,10000000000111111000000000011111b ;論理演算用
jmp key1
color_yellow: mov eax,11111111111000001111111111100000b ;論理演算用
jmp key1
color_violet: mov eax,10000011111111111000001111111111b ;論理演算用
jmp key1
color_skyblue: mov eax,11111100000111111111110000011111b ;論理演算用
jmp key1
color_nega: mov eax,01111111111111110111111111111111b ;論理演算用
jmp key2
jt_koma1: mov eax,2
jmp key3
jt_koma2: mov eax,6
jmp key3
jt_koma3: mov eax,12
key3:
KAKU 300,eax
CALL_P dt3
jmp key
jt_koma4:
CALL_P dt10
jmp key
jmp_mosaic1: mov bx,1919h
jmp key4
jmp_mosaic2: mov bx,5F5Fh
jmp key4
jmp_mosaic3: mov bx,0FFFFh
key4: KAKU 300,bx
CALL_P dt4
jmp key
monotone:
CALL_P dt5
jmp key
zoom_up:
CALL_P dt6
jmp key
zoom_up2:
CALL_P dt7
jmp key
zoom_up3:
CALL_P dt8
jmp key
rever:
CALL_P dt9
jmp key
quit:
mov ax,0100h ;ディジタイズOFF
call zzz
; mov ax,0100h
; mov dx,1
; call zzz ;pword ptr fs:[EGB]
; mov ax,0101h
; mov dx,1
; call zzz ;pword ptr fs:[EGB]
; mov eax,0
; mov edi,0
; mov ecx,400h*256*2/4
; rep stosd
; mov eax,0
; mov edi,40000h
; mov ecx,400h*256*2/4
; rep stosd
; mov ah,1
; call zzz ;pword ptr fs:[MB]
; mov ax,0100h ; キーボード関係設定
; int 90h
; mov ax,4C00h
; int 21h
ret
zzz:
M_ZZZ
key1:
KAKU 300,eax
CALL_P dt1
jmp key
key2:
KAKU 300,eax
CALL_P dt2
jmp key
dt1:
call sub_edi
dw ?
db 'MAIN1',0
dt2:
call sub_edi
dw ?
db 'D_MAIN2',0
dt3:
call sub_edi
dw ?
db 'KOMA',0
dt4:
call sub_edi
dw ?
db 'MOSAIC',0
dt5:
call sub_edi
dw ?
db 'MONO',0
dt6:
call sub_edi
dw ?
db 'ZOOM',0
dt7:
call sub_edi
dw ?
db 'ZOOM2',0
dt8:
call sub_edi
dw ?
db 'ZOOM3',0
dt9:
call sub_edi
dw ?
db 'REVERSE',0
dt10:
call sub_edi
dw ?
db 'D_KOMA',0
look_me:
call sub_esi
dd 0,0
dw 1,0,20,40,0,0,0,0,0,0
p_set:
M_P_SET
p_call:
M_P_CALL
EG equ 0020h
MB equ 0040h
MSR equ 0048h